
package com.sskj.ws.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.security.config.annotation.web.messaging.MessageSecurityMetadataSourceRegistry;
import org.springframework.security.config.annotation.web.socket.AbstractSecurityWebSocketMessageBrokerConfigurer;

@Configuration
public class WebsocketSecurityConfiguration
		extends AbstractSecurityWebSocketMessageBrokerConfigurer {

	@Override
	protected void configureInbound(
			MessageSecurityMetadataSourceRegistry messages) {

		messages.anyMessage().permitAll();
	}

	@Override
	protected boolean sameOriginDisabled() {

		return true;
	}
}
